import request from '@/utils/request';
// import { rsaEncrypt } from '@/utils/commonutils3'

export function getCategorySellList(data) {
	// const data1 = rsaEncrypt(data)
	return request({
		url: '/supplyChain/userBuyInfo',
		method: 'get'
		// params: {
		//   data: data1
		// }
	});
}

export function login(data) {
	// const data1 = rsaEncrypt(data)
	return request({
		url: '/login',
		method: 'post',
		data
	});
}

// 获取用户名
export function getUserSid(data) {
	return request({
		url: '/supplyChain/getUserName',
		method: 'get',
		data
	});
}

// 获取七日出入库统计
export function getSevenDayInOut(data) {
	return request({
		url: '/supplyChain/getInventoryStatistics',
		method: 'get',
		data
	});
}

// 近七日供应商采购排名
export function getSevenDaySupplier(data) {
	return request({
		url: '/supplyChain/supplierRanking',
		method: 'get',
		data
	});
}

// 近七日商品销售排名
export function getSevenDayGoods(data) {
	return request({
		url: '/supplyChain/sellRanking',
		method: 'get',
		data
	});
}

// 库存总货量金额
export function getInventoryTotal(data) {
	return request({
		url: '/supplyChain/inventoryMoney',
		method: 'get',
		data
	});
}

// 获取门店销量排行
export function getStoreSellRanking(data) {
	return request({
		url: '/supplyChain/storeSellRanking',
		method: 'get',
		data
	});
}

// 获取页面数据
export function getPageData(data) {
	return request({
		url: '/supplyChain/pageInfo',
		method: 'get',
		data
	});
}

// 昨日采购入库报告
export function getYesterdayInOut(data) {
	return request({
		url: '/supplyChain/yesterdayInbound',
		method: 'get',
		data
	});
}

// 昨日销售库存总数
export function getYesterdaySell(data) {
	return request({
		url: '/supplyChain/yesterdaySell',
		method: 'get',
		data
	});
}
